package com.yuch.service.impl.activemq;

import org.springframework.jms.annotation.JmsListener;
import org.springframework.messaging.handler.annotation.SendTo;
import org.springframework.stereotype.Component;

@Component
public class Listener {

    @JmsListener(destination = "yuchuang")
    @SendTo("lichuang")
    public String receive(String id){

        System.out.println("消费："+id);
        return "new"+id;
    }
}
